package com.fc.v2.model.auto;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import cn.hutool.core.util.StrUtil;

/**
 * 订单管理 OrderOExample
 * @author fuce_自动生成
 * @date 2021-05-07 14:45:19
 */
public class OrderOExample {

    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public OrderOExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }
        
				
        public Criteria andReserIdIsNull() {
            addCriterion("reser_id is null");
            return (Criteria) this;
        }

        public Criteria andReserIdIsNotNull() {
            addCriterion("reser_id is not null");
            return (Criteria) this;
        }

        public Criteria andReserIdEqualTo(Integer value) {
            addCriterion("reser_id =", value, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdNotEqualTo(Integer value) {
            addCriterion("reser_id <>", value, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdGreaterThan(Integer value) {
            addCriterion("reser_id >", value, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("reser_id >=", value, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdLessThan(Integer value) {
            addCriterion("reser_id <", value, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdLessThanOrEqualTo(Integer value) {
            addCriterion("reser_id <=", value, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdLike(Integer value) {
            addCriterion("reser_id like", value, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdNotLike(Integer value) {
            addCriterion("reser_id not like", value, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdIn(List<Integer> values) {
            addCriterion("reser_id in", values, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdNotIn(List<Integer> values) {
            addCriterion("reser_id not in", values, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdBetween(Integer value1, Integer value2) {
            addCriterion("reser_id between", value1, value2, "reserId");
            return (Criteria) this;
        }

        public Criteria andReserIdNotBetween(Integer value1, Integer value2) {
            addCriterion("reser_id not between", value1, value2, "reserId");
            return (Criteria) this;
        }
        
				
        public Criteria andCusNameIsNull() {
            addCriterion("cus_name is null");
            return (Criteria) this;
        }

        public Criteria andCusNameIsNotNull() {
            addCriterion("cus_name is not null");
            return (Criteria) this;
        }

        public Criteria andCusNameEqualTo(String value) {
            addCriterion("cus_name =", value, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameNotEqualTo(String value) {
            addCriterion("cus_name <>", value, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameGreaterThan(String value) {
            addCriterion("cus_name >", value, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameGreaterThanOrEqualTo(String value) {
            addCriterion("cus_name >=", value, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameLessThan(String value) {
            addCriterion("cus_name <", value, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameLessThanOrEqualTo(String value) {
            addCriterion("cus_name <=", value, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameLike(String value) {
            addCriterion("cus_name like", value, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameNotLike(String value) {
            addCriterion("cus_name not like", value, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameIn(List<String> values) {
            addCriterion("cus_name in", values, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameNotIn(List<String> values) {
            addCriterion("cus_name not in", values, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameBetween(String value1, String value2) {
            addCriterion("cus_name between", value1, value2, "cusName");
            return (Criteria) this;
        }

        public Criteria andCusNameNotBetween(String value1, String value2) {
            addCriterion("cus_name not between", value1, value2, "cusName");
            return (Criteria) this;
        }
        
				
        public Criteria andHNameIsNull() {
            addCriterion("h_name is null");
            return (Criteria) this;
        }

        public Criteria andHNameIsNotNull() {
            addCriterion("h_name is not null");
            return (Criteria) this;
        }

        public Criteria andHNameEqualTo(String value) {
            addCriterion("h_name =", value, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameNotEqualTo(String value) {
            addCriterion("h_name <>", value, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameGreaterThan(String value) {
            addCriterion("h_name >", value, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameGreaterThanOrEqualTo(String value) {
            addCriterion("h_name >=", value, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameLessThan(String value) {
            addCriterion("h_name <", value, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameLessThanOrEqualTo(String value) {
            addCriterion("h_name <=", value, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameLike(String value) {
            addCriterion("h_name like", value, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameNotLike(String value) {
            addCriterion("h_name not like", value, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameIn(List<String> values) {
            addCriterion("h_name in", values, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameNotIn(List<String> values) {
            addCriterion("h_name not in", values, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameBetween(String value1, String value2) {
            addCriterion("h_name between", value1, value2, "hName");
            return (Criteria) this;
        }

        public Criteria andHNameNotBetween(String value1, String value2) {
            addCriterion("h_name not between", value1, value2, "hName");
            return (Criteria) this;
        }
        
				
        public Criteria andSerItemIsNull() {
            addCriterion("ser_item is null");
            return (Criteria) this;
        }

        public Criteria andSerItemIsNotNull() {
            addCriterion("ser_item is not null");
            return (Criteria) this;
        }

        public Criteria andSerItemEqualTo(String value) {
            addCriterion("ser_item =", value, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemNotEqualTo(String value) {
            addCriterion("ser_item <>", value, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemGreaterThan(String value) {
            addCriterion("ser_item >", value, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemGreaterThanOrEqualTo(String value) {
            addCriterion("ser_item >=", value, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemLessThan(String value) {
            addCriterion("ser_item <", value, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemLessThanOrEqualTo(String value) {
            addCriterion("ser_item <=", value, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemLike(String value) {
            addCriterion("ser_item like", value, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemNotLike(String value) {
            addCriterion("ser_item not like", value, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemIn(List<String> values) {
            addCriterion("ser_item in", values, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemNotIn(List<String> values) {
            addCriterion("ser_item not in", values, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemBetween(String value1, String value2) {
            addCriterion("ser_item between", value1, value2, "serItem");
            return (Criteria) this;
        }

        public Criteria andSerItemNotBetween(String value1, String value2) {
            addCriterion("ser_item not between", value1, value2, "serItem");
            return (Criteria) this;
        }
        
				
        public Criteria andPMethodIsNull() {
            addCriterion("p_method is null");
            return (Criteria) this;
        }

        public Criteria andPMethodIsNotNull() {
            addCriterion("p_method is not null");
            return (Criteria) this;
        }

        public Criteria andPMethodEqualTo(String value) {
            addCriterion("p_method =", value, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodNotEqualTo(String value) {
            addCriterion("p_method <>", value, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodGreaterThan(String value) {
            addCriterion("p_method >", value, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodGreaterThanOrEqualTo(String value) {
            addCriterion("p_method >=", value, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodLessThan(String value) {
            addCriterion("p_method <", value, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodLessThanOrEqualTo(String value) {
            addCriterion("p_method <=", value, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodLike(String value) {
            addCriterion("p_method like", value, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodNotLike(String value) {
            addCriterion("p_method not like", value, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodIn(List<String> values) {
            addCriterion("p_method in", values, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodNotIn(List<String> values) {
            addCriterion("p_method not in", values, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodBetween(String value1, String value2) {
            addCriterion("p_method between", value1, value2, "pMethod");
            return (Criteria) this;
        }

        public Criteria andPMethodNotBetween(String value1, String value2) {
            addCriterion("p_method not between", value1, value2, "pMethod");
            return (Criteria) this;
        }
        
				
        public Criteria andAmPayableIsNull() {
            addCriterion("am_payable is null");
            return (Criteria) this;
        }

        public Criteria andAmPayableIsNotNull() {
            addCriterion("am_payable is not null");
            return (Criteria) this;
        }

        public Criteria andAmPayableEqualTo(Double value) {
            addCriterion("am_payable =", value, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableNotEqualTo(Double value) {
            addCriterion("am_payable <>", value, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableGreaterThan(Double value) {
            addCriterion("am_payable >", value, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableGreaterThanOrEqualTo(Double value) {
            addCriterion("am_payable >=", value, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableLessThan(Double value) {
            addCriterion("am_payable <", value, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableLessThanOrEqualTo(Double value) {
            addCriterion("am_payable <=", value, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableLike(Double value) {
            addCriterion("am_payable like", value, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableNotLike(Double value) {
            addCriterion("am_payable not like", value, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableIn(List<Double> values) {
            addCriterion("am_payable in", values, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableNotIn(List<Double> values) {
            addCriterion("am_payable not in", values, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableBetween(Double value1, Double value2) {
            addCriterion("am_payable between", value1, value2, "amPayable");
            return (Criteria) this;
        }

        public Criteria andAmPayableNotBetween(Double value1, Double value2) {
            addCriterion("am_payable not between", value1, value2, "amPayable");
            return (Criteria) this;
        }
        
				
        public Criteria andAcPaidIsNull() {
            addCriterion("ac_paid is null");
            return (Criteria) this;
        }

        public Criteria andAcPaidIsNotNull() {
            addCriterion("ac_paid is not null");
            return (Criteria) this;
        }

        public Criteria andAcPaidEqualTo(Double value) {
            addCriterion("ac_paid =", value, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidNotEqualTo(Double value) {
            addCriterion("ac_paid <>", value, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidGreaterThan(Double value) {
            addCriterion("ac_paid >", value, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidGreaterThanOrEqualTo(Double value) {
            addCriterion("ac_paid >=", value, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidLessThan(Double value) {
            addCriterion("ac_paid <", value, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidLessThanOrEqualTo(Double value) {
            addCriterion("ac_paid <=", value, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidLike(Double value) {
            addCriterion("ac_paid like", value, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidNotLike(Double value) {
            addCriterion("ac_paid not like", value, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidIn(List<Double> values) {
            addCriterion("ac_paid in", values, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidNotIn(List<Double> values) {
            addCriterion("ac_paid not in", values, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidBetween(Double value1, Double value2) {
            addCriterion("ac_paid between", value1, value2, "acPaid");
            return (Criteria) this;
        }

        public Criteria andAcPaidNotBetween(Double value1, Double value2) {
            addCriterion("ac_paid not between", value1, value2, "acPaid");
            return (Criteria) this;
        }
        
				
        public Criteria andOCashierIsNull() {
            addCriterion("o_cashier is null");
            return (Criteria) this;
        }

        public Criteria andOCashierIsNotNull() {
            addCriterion("o_cashier is not null");
            return (Criteria) this;
        }

        public Criteria andOCashierEqualTo(String value) {
            addCriterion("o_cashier =", value, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierNotEqualTo(String value) {
            addCriterion("o_cashier <>", value, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierGreaterThan(String value) {
            addCriterion("o_cashier >", value, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierGreaterThanOrEqualTo(String value) {
            addCriterion("o_cashier >=", value, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierLessThan(String value) {
            addCriterion("o_cashier <", value, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierLessThanOrEqualTo(String value) {
            addCriterion("o_cashier <=", value, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierLike(String value) {
            addCriterion("o_cashier like", value, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierNotLike(String value) {
            addCriterion("o_cashier not like", value, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierIn(List<String> values) {
            addCriterion("o_cashier in", values, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierNotIn(List<String> values) {
            addCriterion("o_cashier not in", values, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierBetween(String value1, String value2) {
            addCriterion("o_cashier between", value1, value2, "oCashier");
            return (Criteria) this;
        }

        public Criteria andOCashierNotBetween(String value1, String value2) {
            addCriterion("o_cashier not between", value1, value2, "oCashier");
            return (Criteria) this;
        }
        
				
        public Criteria andPTimeIsNull() {
            addCriterion("p_time is null");
            return (Criteria) this;
        }

        public Criteria andPTimeIsNotNull() {
            addCriterion("p_time is not null");
            return (Criteria) this;
        }

        public Criteria andPTimeEqualTo(String value) {
            addCriterion("p_time =", value, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeNotEqualTo(String value) {
            addCriterion("p_time <>", value, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeGreaterThan(String value) {
            addCriterion("p_time >", value, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeGreaterThanOrEqualTo(String value) {
            addCriterion("p_time >=", value, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeLessThan(String value) {
            addCriterion("p_time <", value, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeLessThanOrEqualTo(String value) {
            addCriterion("p_time <=", value, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeLike(String value) {
            addCriterion("p_time like", value, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeNotLike(String value) {
            addCriterion("p_time not like", value, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeIn(List<String> values) {
            addCriterion("p_time in", values, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeNotIn(List<String> values) {
            addCriterion("p_time not in", values, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeBetween(String value1, String value2) {
            addCriterion("p_time between", value1, value2, "pTime");
            return (Criteria) this;
        }

        public Criteria andPTimeNotBetween(String value1, String value2) {
            addCriterion("p_time not between", value1, value2, "pTime");
            return (Criteria) this;
        }
        
				
        public Criteria andReMarkIsNull() {
            addCriterion("re_mark is null");
            return (Criteria) this;
        }

        public Criteria andReMarkIsNotNull() {
            addCriterion("re_mark is not null");
            return (Criteria) this;
        }

        public Criteria andReMarkEqualTo(String value) {
            addCriterion("re_mark =", value, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkNotEqualTo(String value) {
            addCriterion("re_mark <>", value, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkGreaterThan(String value) {
            addCriterion("re_mark >", value, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkGreaterThanOrEqualTo(String value) {
            addCriterion("re_mark >=", value, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkLessThan(String value) {
            addCriterion("re_mark <", value, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkLessThanOrEqualTo(String value) {
            addCriterion("re_mark <=", value, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkLike(String value) {
            addCriterion("re_mark like", value, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkNotLike(String value) {
            addCriterion("re_mark not like", value, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkIn(List<String> values) {
            addCriterion("re_mark in", values, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkNotIn(List<String> values) {
            addCriterion("re_mark not in", values, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkBetween(String value1, String value2) {
            addCriterion("re_mark between", value1, value2, "reMark");
            return (Criteria) this;
        }

        public Criteria andReMarkNotBetween(String value1, String value2) {
            addCriterion("re_mark not between", value1, value2, "reMark");
            return (Criteria) this;
        }
        
				
        public Criteria andIdIsNull() {
            addCriterion("id is null");
            return (Criteria) this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion("id is not null");
            return (Criteria) this;
        }

        public Criteria andIdEqualTo(Integer value) {
            addCriterion("id =", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotEqualTo(Integer value) {
            addCriterion("id <>", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThan(Integer value) {
            addCriterion("id >", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("id >=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThan(Integer value) {
            addCriterion("id <", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThanOrEqualTo(Integer value) {
            addCriterion("id <=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLike(Integer value) {
            addCriterion("id like", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotLike(Integer value) {
            addCriterion("id not like", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdIn(List<Integer> values) {
            addCriterion("id in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotIn(List<Integer> values) {
            addCriterion("id not in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdBetween(Integer value1, Integer value2) {
            addCriterion("id between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotBetween(Integer value1, Integer value2) {
            addCriterion("id not between", value1, value2, "id");
            return (Criteria) this;
        }
        
				
        public Criteria andOStateIsNull() {
            addCriterion("o_state is null");
            return (Criteria) this;
        }

        public Criteria andOStateIsNotNull() {
            addCriterion("o_state is not null");
            return (Criteria) this;
        }

        public Criteria andOStateEqualTo(String value) {
            addCriterion("o_state =", value, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateNotEqualTo(String value) {
            addCriterion("o_state <>", value, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateGreaterThan(String value) {
            addCriterion("o_state >", value, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateGreaterThanOrEqualTo(String value) {
            addCriterion("o_state >=", value, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateLessThan(String value) {
            addCriterion("o_state <", value, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateLessThanOrEqualTo(String value) {
            addCriterion("o_state <=", value, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateLike(String value) {
            addCriterion("o_state like", value, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateNotLike(String value) {
            addCriterion("o_state not like", value, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateIn(List<String> values) {
            addCriterion("o_state in", values, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateNotIn(List<String> values) {
            addCriterion("o_state not in", values, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateBetween(String value1, String value2) {
            addCriterion("o_state between", value1, value2, "oState");
            return (Criteria) this;
        }

        public Criteria andOStateNotBetween(String value1, String value2) {
            addCriterion("o_state not between", value1, value2, "oState");
            return (Criteria) this;
        }
        
				
        public Criteria andPIdIsNull() {
            addCriterion("p_id is null");
            return (Criteria) this;
        }

        public Criteria andPIdIsNotNull() {
            addCriterion("p_id is not null");
            return (Criteria) this;
        }

        public Criteria andPIdEqualTo(Integer value) {
            addCriterion("p_id =", value, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdNotEqualTo(Integer value) {
            addCriterion("p_id <>", value, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdGreaterThan(Integer value) {
            addCriterion("p_id >", value, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("p_id >=", value, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdLessThan(Integer value) {
            addCriterion("p_id <", value, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdLessThanOrEqualTo(Integer value) {
            addCriterion("p_id <=", value, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdLike(Integer value) {
            addCriterion("p_id like", value, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdNotLike(Integer value) {
            addCriterion("p_id not like", value, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdIn(List<Integer> values) {
            addCriterion("p_id in", values, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdNotIn(List<Integer> values) {
            addCriterion("p_id not in", values, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdBetween(Integer value1, Integer value2) {
            addCriterion("p_id between", value1, value2, "pId");
            return (Criteria) this;
        }

        public Criteria andPIdNotBetween(Integer value1, Integer value2) {
            addCriterion("p_id not between", value1, value2, "pId");
            return (Criteria) this;
        }
        
			
		 public Criteria andLikeQuery(OrderO record) {
		 	List<String> list= new ArrayList<String>();
		 	List<String> list2= new ArrayList<String>();
        	StringBuffer buffer=new StringBuffer();
			if(record.getReserId()!=null&&StrUtil.isNotEmpty(record.getReserId().toString())) {
    			 list.add("ifnull(reser_id,'')");
    		}
			if(record.getCusName()!=null&&StrUtil.isNotEmpty(record.getCusName().toString())) {
    			 list.add("ifnull(cus_name,'')");
    		}
			if(record.getHName()!=null&&StrUtil.isNotEmpty(record.getHName().toString())) {
    			 list.add("ifnull(h_name,'')");
    		}
			if(record.getSerItem()!=null&&StrUtil.isNotEmpty(record.getSerItem().toString())) {
    			 list.add("ifnull(ser_item,'')");
    		}
			if(record.getPMethod()!=null&&StrUtil.isNotEmpty(record.getPMethod().toString())) {
    			 list.add("ifnull(p_method,'')");
    		}
			if(record.getAmPayable()!=null&&StrUtil.isNotEmpty(record.getAmPayable().toString())) {
    			 list.add("ifnull(am_payable,'')");
    		}
			if(record.getAcPaid()!=null&&StrUtil.isNotEmpty(record.getAcPaid().toString())) {
    			 list.add("ifnull(ac_paid,'')");
    		}
			if(record.getOCashier()!=null&&StrUtil.isNotEmpty(record.getOCashier().toString())) {
    			 list.add("ifnull(o_cashier,'')");
    		}
			if(record.getPTime()!=null&&StrUtil.isNotEmpty(record.getPTime().toString())) {
    			 list.add("ifnull(p_time,'')");
    		}
			if(record.getReMark()!=null&&StrUtil.isNotEmpty(record.getReMark().toString())) {
    			 list.add("ifnull(re_mark,'')");
    		}
			if(record.getId()!=null&&StrUtil.isNotEmpty(record.getId().toString())) {
    			 list.add("ifnull(id,'')");
    		}
			if(record.getOState()!=null&&StrUtil.isNotEmpty(record.getOState().toString())) {
    			 list.add("ifnull(o_state,'')");
    		}
			if(record.getPId()!=null&&StrUtil.isNotEmpty(record.getPId().toString())) {
    			 list.add("ifnull(p_id,'')");
    		}
			if(record.getReserId()!=null&&StrUtil.isNotEmpty(record.getReserId().toString())) {
    			list2.add("'%"+record.getReserId()+"%'");
    		}
			if(record.getCusName()!=null&&StrUtil.isNotEmpty(record.getCusName().toString())) {
    			list2.add("'%"+record.getCusName()+"%'");
    		}
			if(record.getHName()!=null&&StrUtil.isNotEmpty(record.getHName().toString())) {
    			list2.add("'%"+record.getHName()+"%'");
    		}
			if(record.getSerItem()!=null&&StrUtil.isNotEmpty(record.getSerItem().toString())) {
    			list2.add("'%"+record.getSerItem()+"%'");
    		}
			if(record.getPMethod()!=null&&StrUtil.isNotEmpty(record.getPMethod().toString())) {
    			list2.add("'%"+record.getPMethod()+"%'");
    		}
			if(record.getAmPayable()!=null&&StrUtil.isNotEmpty(record.getAmPayable().toString())) {
    			list2.add("'%"+record.getAmPayable()+"%'");
    		}
			if(record.getAcPaid()!=null&&StrUtil.isNotEmpty(record.getAcPaid().toString())) {
    			list2.add("'%"+record.getAcPaid()+"%'");
    		}
			if(record.getOCashier()!=null&&StrUtil.isNotEmpty(record.getOCashier().toString())) {
    			list2.add("'%"+record.getOCashier()+"%'");
    		}
			if(record.getPTime()!=null&&StrUtil.isNotEmpty(record.getPTime().toString())) {
    			list2.add("'%"+record.getPTime()+"%'");
    		}
			if(record.getReMark()!=null&&StrUtil.isNotEmpty(record.getReMark().toString())) {
    			list2.add("'%"+record.getReMark()+"%'");
    		}
			if(record.getId()!=null&&StrUtil.isNotEmpty(record.getId().toString())) {
    			list2.add("'%"+record.getId()+"%'");
    		}
			if(record.getOState()!=null&&StrUtil.isNotEmpty(record.getOState().toString())) {
    			list2.add("'%"+record.getOState()+"%'");
    		}
			if(record.getPId()!=null&&StrUtil.isNotEmpty(record.getPId().toString())) {
    			list2.add("'%"+record.getPId()+"%'");
    		}
        	buffer.append(" CONCAT(");
	        buffer.append(StrUtil.join(",",list));
        	buffer.append(")");
        	buffer.append(" like CONCAT(");
        	buffer.append(StrUtil.join(",",list2));
        	buffer.append(")");
        	if(!" CONCAT() like CONCAT()".equals(buffer.toString())) {
        		addCriterion(buffer.toString());
        	}
        	return (Criteria) this;
        }
        
        public Criteria andLikeQuery2(String searchText) {
		 	List<String> list= new ArrayList<String>();
        	StringBuffer buffer=new StringBuffer();
    		list.add("ifnull(reser_id,'')");
    		list.add("ifnull(cus_name,'')");
    		list.add("ifnull(h_name,'')");
    		list.add("ifnull(ser_item,'')");
    		list.add("ifnull(p_method,'')");
    		list.add("ifnull(am_payable,'')");
    		list.add("ifnull(ac_paid,'')");
    		list.add("ifnull(o_cashier,'')");
    		list.add("ifnull(p_time,'')");
    		list.add("ifnull(re_mark,'')");
    		list.add("ifnull(id,'')");
    		list.add("ifnull(o_state,'')");
    		list.add("ifnull(p_id,'')");
        	buffer.append(" CONCAT(");
	        buffer.append(StrUtil.join(",",list));
        	buffer.append(")");
        	buffer.append("like '%");
        	buffer.append(searchText);
        	buffer.append("%'");
        	addCriterion(buffer.toString());
        	return (Criteria) this;
        }
        
}
	
    public static class Criteria extends GeneratedCriteria {
        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}